package com.itheima.reggie.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.itheima.reggie.entity.Category;
import com.itheima.reggie.entity.R;

/**
 * <b><code>ICategoryService</code></b>
 * <p/>
 * Description
 * <p/>
 * <b>Creation Time:</b> 24/06/2024 15:35.
 *
 * @author yanjr
 * @since reggie_take_out
 */
public interface ICategoryService extends IService<Category> {
    /**
     * 菜品分页查询
     * @param page 当前页
     * @param pageSize 每页显示条数
     * @return 查询的分页结果
     */
    R<Page<Category>> queryCategory(int page, int pageSize);

    /**
     * 删除分类
     * @param id 分类id
     * @return 是否成功
     */
    R<String> deleteCategoryById(Long id);
}
